using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Content;

namespace Zephyris_Space_Mercs
{
    class UI
    {
        private SpriteBatch spriteBatch;
        private SpriteBatch buttonBatch;

        public UI(SpriteBatch spriteBatch, SpriteBatch buttonBatch)
        {
            this.spriteBatch = spriteBatch;
            this.buttonBatch = buttonBatch;
        }


        public void drawScreen(Texture2D screenTexture)
        {
            this.spriteBatch.Draw(screenTexture, new Vector2(0, 0), Color.White);
        }

        public void drawBar(Texture2D barTexture, Vector2 topLeftCorner)
        {
            this.spriteBatch.Draw(barTexture, topLeftCorner, Color.White);
        }

        public void drawButton(Texture2D buttonTexture, Vector2 topLeftCorner, SpriteFont font, string text)
        {

            this.buttonBatch.Draw(buttonTexture, topLeftCorner, new Color(255, 255, 255, 255));
            
            this.buttonBatch.DrawString(font, text, new Vector2(topLeftCorner.X + 35, topLeftCorner.Y + 2), Color.White);
        }

        public void drawText(Vector2 topLeftCorner, SpriteFont font, string text)
        {
            this.buttonBatch.DrawString(font, text, new Vector2(topLeftCorner.X, topLeftCorner.Y), Color.Green);
        }
    }
}
